Repository navigation
grep: allow later options to override earlier ones in option groups - #245
yunusarda-sudo wants to merge 1 commit into
Conversation
Merging this PR will not alter performance1 warning
Comparing Footnotes
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #245 +/- ##
==========================================
+ Coverage 97.22% 97.23% +0.01%
==========================================
Files 6 6
Lines 2270 2280 +10
Branches 245 246 +1
==========================================
+ Hits 2207 2217 +10
Misses 63 63
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
c4e6e7c to
bc618a5
Compare
|
Cygwin failure is unrelated: |
8fcd2ee to
6dc6ee5
Compare
Configure clap argument overrides for -a / -I / --binary-files, -r / -R / -d, and --group-separator / --no-group-separator so that the later option takes precedence over an earlier one as GNU grep does. Fixes uutils#177 Signed-off-by: Yunus Arda Güney <yunusarda-sudo@users.noreply.github.com>
6dc6ee5 to
8637414
Compare
When conflicting options within the same group were specified on the command line:
-aalways beat-I, which always beat--binary-files=TYPE;-r/-Ralways beat-d ACTION;--no-group-separatoralways beat--group-separator=SEP.This PR sets up mutual argument overrides for these option groups so that whichever option appears last takes precedence, matching GNU grep behavior.
Fixes #177